package src.VO;

import java.io.Serializable;
import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

import org.openswing.swing.message.receive.java.ValueObjectImpl;

import com.j256.ormlite.field.DataType;
import com.j256.ormlite.field.DatabaseField;


/**
 * The persistent class for the clients database table.
 * 
 */
@Entity(name="clients")
public class ClientVO extends ValueObjectImpl implements Serializable {
	private static final long serialVersionUID = 1L;

	@Id
	@Column(updatable=false)
	private int idclients;
	@DatabaseField
	private String address;
 
	@DatabaseField(columnName="date_birth", dataType=DataType.DATE)
	private Date dateBirth;

	@Column(name="e_mail")
	private String eMail;
	@DatabaseField
	private String name;
	@DatabaseField
	private String passport;
	@DatabaseField
	private String phone;
	@DatabaseField
	private String sex;

	
    public ClientVO() {
    }

    
	public ClientVO(String address, Date dateBirth, String eMail, String name,
			String passport, String phone, String sex) {
		this.address = address;
		this.dateBirth = dateBirth;
		this.eMail = eMail;
		this.name = name;
		this.passport = passport;
		this.phone = phone;
		this.sex = sex;
	}


	public int getIdclients() {
		return this.idclients;
	}

	private void setIdclients(int idclients) {
		this.idclients = idclients;
	}

	public String getAddress() {
		return this.address;
	}

	public void setAddress(String address) {
		this.address = address;
	}

	public Date getDateBirth() {
		return this.dateBirth;
	}

	public void setDateBirth(Date dateBirth) {
		this.dateBirth = dateBirth;
	}

	public String getEMail() {
		return this.eMail;
	}

	public void setEMail(String eMail) {
		this.eMail = eMail;
	}

	public String getName() {
		return this.name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getPassport() {
		return this.passport;
	}

	public void setPassport(String passport) {
		this.passport = passport;
	}

	public String getPhone() {
		return this.phone;
	}

	public void setPhone(String phone) {
		this.phone = phone;
	}

	public String getSex() {
		return this.sex;
	}

	public void setSex(String sex) {
		this.sex = sex;
	}

	public static String getIdString(){
		return "idclients";
	}
	
	public static String getNameString(){
		return "name";
	}
	
	public static String getSexString(){
		return "sex";
	}
	
	public static String getDateBString(){
		return "dateBirth";
	}
	
	public static String getAddressString(){
		return "address";
	}
	
	public static String getPhoneString(){
		return "phone";
	}
	
	public static String getEmailString(){
		return "eMail";
	}
	public static String getPassportString(){
		return "passport";
	}


	/* (non-Javadoc)
	 * @see java.lang.Object#toString()
	 */
	@Override
	public String toString() {
		return "ClientVO [idclients=" + idclients + ", address=" + address
				+ ", dateBirth=" + dateBirth + ", eMail=" + eMail + ", name="
				+ name + ", passport=" + passport + ", phone=" + phone
				+ ", sex=" + sex + "]";
	}
	
	

}